Dynamic background estimation for video analysis using evolutionary optimization

ABSTRACT

Described is a system for dynamic background estimation which utilizes Particle Swarm Optimization (PSO). The present invention comprises a system, method, and computer program product for accurate estimation of a background mask corresponding to a dynamically changing scene. The system is configured to construct a background template model of a scene, and then capture an image of a current view of the scene with a camera. Thereafter, the system generates an image-based template matching cost function as an optimization problem, where the objective is to identify and fit a corresponding subregion of the background template model to the current camera view. The cost function is optimized using a PSO search algorithm. Finally, the system is configured to generate the corresponding subregion of the background template model for display. The inherent efficiency of PSO makes this system conducive for use in applications requiring real-time background estimation.

PRIORITY CLAIM

The present application is a Continuation-in-Part Application of U.S. patent Ser. No. 11/367,755, filed Mar. 4, 2006, entitled, “Object Recognition Using a Cognitive Swarm Vision Framework with Attention Mechanisms” which claims the benefit of priority of U.S. Provisional Patent Application No. 60/658,942, filed Mar. 4, 2005, entitled, “Object Recognition Using a Cognitive Swarm Vision Framework with Attention Mechanisms.”

BACKGROUND OF THE INVENTION

(1) Field of Invention

The present invention relates to a system for background estimation and, more particularly, to a system for background estimation which allows estimation of a stationary background mask of a dynamically changing view utilizing particle swarm optimization.

(2) Description of Related Art

Background estimation mechanisms have application in vision-based reconnaissance and security systems. These types of applications require accurate and fast object (i.e., people, cars, inanimate objects) detection capabilities and, therefore, would benefit greatly from reliable background estimation mechanisms as a way of initial detection and segmentation of foreground objects in a scene. Furthermore, a successful dynamic background estimation mechanism can greatly reduce the computational load of any machine vision-based object and event recognition system.

An increasing number of object tracking algorithms with active cameras have surfaced in recent literature. For instance, in “A Real-Time Tracking of Multiple Moving Object Contours in a Moving Camera Image Sequence” by S. Araki et. al in Transactions on Information and Systems, IEICE 2000, the authors propose algorithms which successfully track interested objects under various conditions. However, the object tracking algorithms fail to identify slow-moving or partially-moving objects, such as a stationary pedestrian waving his hands. These systems would greatly benefit from dynamic background estimation.

Additional prior art in background estimation and the use of background masks has been constrained primarily to stationary cameras, and often, to stationary backgrounds. Most prior art attempts to estimate the changing background by accumulating pixel information from a currently incident background requires accumulation of pixel information over several frames. During this background learning phase, the camera must remain stationary.

A few more sophisticated algorithms have recently surfaced which attempt to address small camera motions. In a recent paper entitled, “A Real-Time Background Subtraction Method with Camera Motion Compensation” by Tiehan Lv et al. in Proceedings of International Conference on Multimedia and Expo (ICME), 2004, the authors propose a background estimation and subtraction algorithm that is designed to work with a “shaking” camera. The method by Lv et al. relies on small incremental camera motion and accurate estimation of camera motion on the fly. Clearly, this and other methods are bound for failure in the case of wide-baseline camera movements.

It is well known in the art that solutions to challenging background estimation problems are fundamental to creation of next generation vision-based classification and tracking systems, particularly in moving camera settings. The present invention described herein is in response to present challenges in background estimation for moving cameras involving wide baseline displacements.

SUMMARY OF THE INVENTION

The present invention relates to a system for background estimation comprising one or more processors configured to perform operations of first capturing an image subregion of a current scene. A cost function is then optimized through utilization of a plurality of particles which operates as a cooperative swarm in sampling the cost function over a search domain of a background template model and iteratively migrates towards an optimal solution. The optimal solution is a subregion of the background template model which corresponds to the image subregion of the current scene. Finally, the subregion of the background template model which corresponds to the image subregion of the current scene is generated.

In another aspect, the cost function to be optimized is J(x)=d(I(x),Io), with J:

²→[0, 1], where I_(o)∈

^(w×h) represents the image corresponding to the current scene, I(x)∈

^(w×h) represents an image corresponding to a portion of the search domain of the background model template having the same dimensions as I_(o)∈9

^(w×h), where x is an input parameter, d(.) represents an image similarity measure,

denotes the set of real numbers, w is the width of the image, h is the height of the image, ∈ denotes an element of, and → represents a function arrow.

In yet another aspect, the image similarity measure is selected from the group consisting of normalized cross correlation, L2 distances, and mutual information.

In another aspect, the image similarity measure varies gradually with respect to at least one misalignment between the background template and the current scene.

In another aspect, in the act of optimizing the cost function, the plurality of particles begin at a randomly initialized state where each particle migrates towards the optimal solution in the search domain according to the following: x _(i)(t+1)=F(x _(i)(t),pbest_(i)(t),gbest(t)), where x(t) corresponds to a trajectory of a particle i, pbest represents a particle's current best solution found up to time t, and gbest represents a current global best solution among all particles up to time t.

As can be appreciated by one in the art, the present invention also comprises a method for performing the operations described herein.

As can be appreciated by one in the art, the present invention also comprises a computer program product comprising computer-readable instruction means stored on a computer-readable medium that are executable by a computer having a processor for causing the processor to perform the operations described herein.

BRIEF DESCRIPTION OF THE DRAWINGS

The objects, features and advantages of the present invention will be apparent from the following detailed descriptions of the various aspects of the invention in conjunction with reference to the following drawings, where:

FIG. 1A is an illustration of a background template model of a scene according to the present invention;

FIG. 1B is an illustration of a current camera view of the scene according to the present invention;

FIG. 2A is an illustration of a subregion of a background template model according to the present invention;

FIG. 2B is an illustration of a current camera view of the subregion according to the present invention;

FIG. 2C is an illustration of a foreground mask of the subregion according to the present invention;

FIG. 3 is an illustration of a background identification according to the present invention;

FIG. 4 depicts an illustration of intensity plots of image similarity measures over a search domain according to the present invention;

FIG. 5 illustrates a system for background estimation according to the present invention;

FIG. 6 is an illustration of a data processing system according to the present invention; and

FIG. 7 is an illustration of a computer program product according to the present invention.

DETAILED DESCRIPTION

The present invention relates to system for background estimation and, more particularly, to a system for background estimation which allows estimation of a stationary background mask of a dynamically changing view utilizing particle swarm optimization when the background mask is a subregion of a larger background image. The following description is presented to enable one of ordinary skill in the art to make and use the invention and to incorporate it in the context of particular applications. Various modifications, as well as a variety of uses, in different applications will be readily apparent to those skilled in the art, and the general principles defined herein may be applied to a wide range of embodiments. Thus, the present invention is not intended to be limited to the embodiments presented, but is to be accorded with the widest scope consistent with the principles and novel features disclosed herein.

In the following detailed description, numerous specific details are set forth in order to provide a more thorough understanding of the present invention. However, it will be apparent to one skilled in the art that the present invention may be practiced without necessarily being limited to these specific details. In other instances, well-known structures and devices are shown in block diagram form, rather than in detail, in order to avoid obscuring the present invention.

The reader's attention is directed to all papers and documents which are filed concurrently with this specification and which are open to public inspection with this specification, and the contents of all such papers and documents are incorporated herein by reference. All the features disclosed in this specification, (including any accompanying claims, abstract, and drawings) may be replaced by alternative features serving the same, equivalent or similar purpose, unless expressly stated otherwise. Thus, unless expressly stated otherwise, each feature disclosed is one example only of a generic series of equivalent or similar features.

Furthermore, any element in a claim that does not explicitly state “means for” performing a specified function, or “step for” performing a specific function, is not to be interpreted as a “means” or “step” clause as specified in 35 U.S.C. Section 112, Paragraph 6. In particular, the use of “step of” or “act of” in the claims herein is not intended to invoke the provisions of 35 U.S.C. 112, Paragraph 6.

Please note, if used, the labels left, right, front, back, top, bottom, forward, reverse, clockwise and counter-clockwise have been used for convenience purposes only and are not intended to imply any particular fixed direction. Instead, they are used to reflect relative locations and/or directions between various portions of an object. As such, as the present invention is changed, the above labels may change their orientation.

(1) PRINCIPAL ASPECTS

The present invention has three “principal” aspects. The first is a system for background estimation. The system is typically in the form of a computer system, computer component, or computer network operating software or in the form of a “hard-coded” instruction set. This system may take a variety of forms with a variety of hardware devices and may include computer networks, handheld computing devices, cellular networks, satellite networks, and other communication devices. As can be appreciated by one skilled in the art, this system may be incorporated into a wide variety of devices that provide different functionalities. The second principal aspect is a method for rapid feature matching for aligning backgrounds in visual systems, typically in the form of software, operated using a data processing system (computer or computer network). The third principal aspect is a computer program product. The computer program product generally represents computer-readable instruction means stored on a computer-readable medium such as an optical storage device, e.g., a compact disc (CD) or digital versatile disc (DVD), or a magnetic storage device such as a floppy disk or magnetic tape. Other, non-limiting examples of computer-readable media include hard disks, read-only memory (ROM), and flash-type memories.

The term “instruction means” as used with respect to this invention generally indicates a set of operations to be performed on a computer, and may represent pieces of a whole program or individual, separable, software modules. Non-limiting examples of “instruction means” include computer program code (source or object code) and “hard-coded” electronics (i.e. computer operations coded into a computer chip). The “instruction means” may be stored in the memory of a computer or on a computer-readable medium such as a floppy disk, a CD-ROM, and a flash drive. These aspects will be described in more detail below.

(2) INTRODUCTION

This present invention provides a background estimation method given an a priori learned background template. Background estimation is one of the fundamental elements of vision-based tracking and recognition systems. Once the stationary background of a region can be identified, it can be subtracted from a dynamic image to yield only the dynamic portion. The dynamic portion will comprise fewer data points and, as such, any analysis of the dynamic portion will execute faster than if the entire view had to be processed. Most existing methods for background subtraction are severely hindered by any type of camera motion. The algorithm presented here is precise, efficient, and capable of coping with wide base camera movements. Furthermore, due to the previously mentioned characteristics, it is suitable for targeting real-time applications. Typically, on the fly background estimation is done by accumulating information on background pixels over a period of video frames while the camera remains stationary. Moving camera paradigms involving large displacements are therefore not suitable for the commonly used background estimation techniques. The present invention provides a solution to the continuous dynamic background estimation problem for moving cameras.

(3) SPECIFIC DETAILS

The present invention relates to a system, method, and computer program product for estimating the stationary background mask of a dynamically changing view captured through a camera that is actively scanning (e.g., pan and tilt) through a wide viewing volume. In the present invention, the camera is moving in azimuth and elevation or pan and tilt. The point of view does not change as the camera is fixed on one location. The background image is also fixed, and a candidate dynamic image covers a section of the background which has an object (e.g., person) in it. The purpose of the present invention is to subtract out the relevant background and focus on the object.

As illustrated in FIG. 1A, a large global background template model 100 of a scene is constructed and learned a priori. As a non-limiting example, the approach to building the background template model involves using a Gaussian at each pixel in the scent to represent the background. A snippet of the background-only image is used, and statistics are computed to define the Gaussians for each pixel. This approach for building the background model is further described by Wren et al. in “Pfinder: Real-Time Tracking of the Human Body”, IEEE Trans. Pattern Analysis and Machine Intelligence, vol. 19, no. 7, 1997, which is hereby incorporated by reference as though fully included herein. When a camera is incident on a small subregion 102 in the scene, as shown in FIG. 1B, the objective is to identify and accurately fit the corresponding background subregion 104 from the larger background template model 100 to the camera's current view of the subregion 102. While the background (a priori model) is assumed stationary and will remain invariant to geometric and luminance factors, such as viewing angle and lighting conditions, the foreground is expected to change as a result of occluding foreground objects, such as pedestrians. The application of the present invention is aimed for real-time surveillance systems, thus the efficiency and speed of the algorithm is essential. This is achieved through an innovative combination of a template matching cost function in conjunction with an efficient search mechanism based on Particle Swarm Optimization. The combination provides a superior alternative to carrying out a computationally expensive background template matching scheme that would exhaustively search for the current view of the subregion within the global background template model.

FIG. 2B is an illustration of a current camera view 200. FIG. 2A depicts a matching background patch 202 from the background template model. As shown in FIG. 2C, a foreground mask 204 is extracted by matching the appropriate background mask from the background template model.

(3.1) Template Matching Cost Function

FIG. 3 illustrates a background identification task posed as a minimization of a template matching cost function that attempts to identify the nominal parameter (x*) for the parameterized patch I(x) in a global background template model 300. A primary element of the invention proposed here is the image-based cost function d(I(x),Io) that allows casting of the background matching task as an optimization problem. Let I_(o)∈

^(w×h) be the image corresponding to the current camera view 302 and I(x)∈

^(W×h) be the image of the same dimensions corresponding to a rectangular patch, or subregion, of the template 304 centered at x∈Ω⊂

². The search domain Ω 306 is defined such that all possible rectangular windows of size (w by h) can be accommodated.

The background estimation task can be formalized as: x*=arg min d(I(x),I _(o)) Additionally, the cost function to be optimized is J(x)=d(I(x),Io), with J:

²→[0, 1]. J(x) takes a parameter x as input and outputs a normalized scalar score corresponding the match between the current camera view and background template patch. The choice of the image similarity measure d(.) is significant, since the optimization paradigm used will involve partly stochastic, sparse sampling of the search space. Therefore, it is highly advantageous for d(.) to exhibit regular continuous variation around the nominal value x*, ideally a Lipschitz continuous function of x. The optimal choice of the image similarity measure depends ultimately on the nature of the images. For most scenes, one might opt for simple L2 type distances or normalized cross correlation. L2 type distances are the sum of the squares of the difference in intensities between two aligned or registered images. An equivalent notation for L2 type distances is ∥I(x)−Io∥². What is needed is a matching function that varies gradually with respect to small misalignments between the template and the current camera view but one that, at the same time, allows for precision alignment of the background template. It has been shown in the literature that entropic similarity measures (or mutual information measures) between images have desirable properties for precision template registration. Pixel intensity probability distributions used to compute mutual information do not vary irregularly with small geometric misalignments or local lighting changes between images which makes mutual information the preferred choice for the task.

FIG. 4 depicts illustrations of intensity plots of three different image similarity measures, J(x)=d(I(x),Io), over the limited search domain Ω 400 of the background template model 402 using several different image similarity measures. The intensity plots illustrate contours of constant intensity in the images, with the enclosed regions being most intense. The image similarity measures used include mutual information 404, L2 distances 406, and normalized cross correlation 408. As predicted by analysis, mutual information 404 exhibits the sharpest peak 405 (the smallest area within a given contour of constant intensity) around the target, in this case a pedestrian 410. While normalized cross correlation 408 exhibits a smoother variation 409 over a wider area around the neighborhood of the target 410, the precision peak 405 for the mutual information 404 is clearly more pronounced.

Mutual information between two random variables I(X;Y) is defined as follows:

${I\left( {X;Y} \right)} = {\int_{Y}{\int_{X}{{p\left( {x,y} \right)}{\log\left( \frac{p_{XY}\left( {x,y} \right)}{{p_{X}(x)}{p_{Y}(y)}} \right)}{{dxdy}.}}}}$ In the present application, X represents a first distribution (e.g., background image), and Y represents a second distribution (e.g., candidate image). x and y represent the intensities of the background image and the candidate image, respectively. p_(X) represents the distribution of pixel intensities of image X, and p_(Y) represents the distribution of pixel intensities. p_(XY) denotes the joint distribution of the two images X and Y (i.e., the distribution of intensities for the overlap of the two images). Given a camera, the direction of the camera is known such that for any image obtained, the Cartesian coordinates of any point in the image can be determined. In the present invention, since the same camera is to be used for both the background image and the candidate dynamic image, the two images can be registered, or aligned. Therefore, upon overlay or registering of the two images, a pair of intensities can be obtained for each pixel. The joint distribution described above is a histogram of the pairs of intensities.

With mutual information as the image similarity measure d(.), the second primary element of the algorithm is the search algorithm for finding the target x. The present system utilizes Particle Swarm Optimization (PSO) as its search algorithm. In PSO, a set of n active particles sample the cost function over the search space sparsely, and iteratively move towards the optimal point x*. Starting at randomly initialized state x_(i)(t=0)x_(i) _(o) , every point i in the set migrates towards the minima in the parameter search space according to the PSO dynamics: x _(i)(t+1)=F(x _(i)(t),pbest_(i)(t),gbest(t)).

In this case, pbest(t) corresponds to a particle's best (optimal value) in its trajectory so far, and gbest represents a global optimal value for all particles up to time t. F(.) represents the particle's dynamic evolution (e.g., its next position in the search or solution space) as a function of its current position or state, the best local value pbest and the best global value gbest. The form of F(.) is described in the next section.

(3.2) Particle Swarm Optimization

Particle Swarm Optimization (PSO) is an optimization method that has its roots in artificial life, specifically bird flocking and swarming theory. PSO is a simple but powerful population-based algorithm that is effective for optimization of a wide range of functions as described by Kennedy et al. in “Swarm Intelligence”, San Francisco: Morgan Kaufmann Publishers, 2001, and by Eberhart and Shi in “Particle Swarm Optimization: Developments, Applications, and Resources”, 2001, which is hereby incorporated by reference as though fully included herein. The basic idea is relatively simple, minimize (or maximize) a cost function f(x) with f:∈

^(n)→

, using a swarm of dynamic particles that cooperatively search the parameter solution space, x∈Ω⊂

^(n), searching for the minima. Each particle evaluates the cost function along its trajectory x(t), while keeping track of the best solution it has found so far (pbest), where f(x) is minimized along x(t). The current best (optimal) solution among all the points is also tracked using a global best parameter (gbest). At any given time t, the velocity of particle i, v(t), is then updated to point towards pbest and gbest, up to a random factor defined by system parameters. The particle dynamics is described by the following state evolution equations: v _(i)(t+1)=wv _(i)(t)+c ₁ q(pbest−x _(i)(t))+c ₂ q(gbest−x _(i)(t)) x _(i)(t+1)=x _(i)(t)+v _(i)(t+1).

This is essentially a discrete time dynamical system. Here x_(i)(t) and v_(i)(t) are the position and velocity vectors. At time t of the i-th particle, q˜[0,1] is a uniformly distributed random variable, and c₁ and c₂ are parameters that weigh the influence of their respective terms in the velocity update equation. w is a decay constant which controls the swarm's asymptotic (convergence) behavior. The parameter q facilitates an initially random search of the solution space. The search becomes more directed after a few iterations, depending on f(x) and system parameters, as the swarm is attracted towards “favorable” regions.

PSO operates on the assumption that in most practical problems, good solutions usually have better than average solutions residing in a volume around the best solution. These “halo” solutions tend to attract the swarm and concentrate it on regions that are likely to contain good solutions, which make PSO search very efficient. PSO is similar to other evolutionary methods in that it does not use gradient information and can be used with ill-behaved cost functions. Furthermore, it has been found, through empirical simulations, that the number of particles and iterations required scale weakly with the dimensionality of the solution space.

FIG. 5 illustrates the system for background estimation according to the present invention. First, a background template model of a scene is constructed a priori 500. Thereafter, an image of a current view of a subregion of the scene is captured with a camera 502. Next, an image-based template matching cost function is generated 504, and the cost function is optimized through PSO. In PSO, the particles operate as a cooperative swarm in sampling the cost function over a search domain of the background template model and iteratively migrate toward an optimal solution 506. Finally, a subregion of the background template model which corresponds to the camera's current view of the subregion is generated for display to a user 508.

FIG. 6 illustrates a block diagram depicting components of a data processing system 600 (e.g., computer) incorporating the operations of the method described above. The method utilizes a data processing system 600 for storing computer executable instructions for causing a processor to carry out the operations of the above described method. The data processing system 600 comprises an input 602 for receiving information from a user. Information received may include input from devices such as cameras, scanners, keypads, keyboards, microphone, other peripherals such as storage devices, other programs, etc. The input 602 may include multiple “ports.” An output 604 is connected with a processor 606 for providing information for transmission to other data processing systems, to storage devices, to display devices such as monitors, to generating information necessary for delivery, and to other mechanisms for presentation in user-usable forms. The input 602 and the output 604 are both coupled with the processor 606, which may be a general-purpose computer processor or a specialized processor designed specifically for use with the present invention. The processor 606 is coupled with a memory 608 to permit storage of data and software to be manipulated by commands to the processor 606.

An illustrative diagram of a computer program product embodying the present invention is depicted in FIG. 7. As a non-limiting example, the computer program product is depicted as either a floppy disk 700 or an optical disk 702. However, as mentioned previously, the computer program product generally represents computer readable code stored on any compatible computer readable medium.

(4) CONCLUSION

In the present invention, a system, method, and computer program product is devised for accurate estimation of a background mask corresponding to a dynamically changing scene by efficiently searching through an a priori learned global background model using entropic similarity measures. The inherent efficiency of PSO makes this system conducive for use in applications requiring real-time background estimation. This present invention comprises an innovative combination of primary elements which include an image-based template matching cost function and a PSO framework. The image-based template matching cost function varies continuously around the neighborhood of a target. Furthermore, the PSO framework is conducive for finding extremes of non-convex functions without the need for computation of gradients or exhaustive or dense sampling of the cost function within the objective function's search domain. The continuous variation of the cost function is a necessary element for the PSO which functions by stochastic sparse sampling of the objective function. 

What is claimed is:
 1. A system for background estimation, the system comprising one or more processors that are configured to perform operations of: constructing and learning a background template model of a field-of view of a scene captured with a camera a priori; capturing a current image of the scene with the camera, the current image of the scene having a dynamically changing field-of-view of the scene that is smaller than the field-of-view of the background template model; minimizing a template matching cost function to identify a parameter x* for a parameterized patch of the background template model which corresponds to the camera's current field-of-view, wherein the template matching cost function takes a parameter x as input and outputs a normalized scalar score corresponding to a match between the camera's current field-of-view and the parameterized patch of the background template model using an image similarity measure selected from the group consisting of normalized cross correlation and L2 distances, wherein the template matching cost function is minimized through utilization of a plurality of particles which operates as a cooperative swarm in sampling the cost function over a search domain of the background template model and iteratively migrates towards the parameter x*; for each current field-of-view, continuously matching the camera's current field-of-view with the parameterized patch of the background template model; subtracting the parameterized patch of the background template model from the camera's current field-of-view to extract a foreground mask; and generating a display of the foreground mask for detecting at least one object of interest within the foreground mask.
 2. A system for background estimation as set forth in claim 1, wherein the cost function to be optimized is J(x)=d(I(x),Io), with J:

²→[0, 1], where I_(o)∈

^(w×h) represents the image corresponding to the current scene, I(x)∈

^(w×h) represents an image corresponding to the parameterized patch of the background template model centered at x∈Ω⊂R² having the same dimensions as I_(o)∈

^(w×h), where x is an input parameter, d(.) represents an image similarity measure, R denotes the set of real numbers, w is the width of the image, h is the height of the image, ∈ denotes an element of, Ω represents the search domain, and → represents a function arrow.
 3. A system for background estimation as set forth in claim 2, wherein the image similarity measure varies with respect to at least one misalignment between the background template and the current scene.
 4. A system for background estimation as set forth in claim 3, wherein in the act of optimizing the cost function, the plurality of particles begin at a randomly initialized state, where each particle migrates towards the optimal solution in the search domain according to the following: x _(i)(t+1)=F(x _(i)(t),pbest_(i)(t),gbest(t)), where x(t) corresponds to a particle i's trajectory, pbest represents a particle's current best solution found up to time t, gbest represents a current global best solution among all particles up to time t, and F(.) represents a particle's dynamic evolution as a function of its current position or state, pbest, and gbest.
 5. A computer-implemented method for background estimation, the method comprising an act of causing a processor to perform operations of: constructing and learning a background template model of a field-of view of a scene captured with a camera a priori; constructing and learning a background template model of a field-of view of a scene captured with a camera a priori; capturing a current image of the scene with the camera, the current image of the scene having a dynamically changing field-of-view of the scene that is smaller than the field-of-view of the background template model; minimizing a template matching cost function to identify a parameter x* for a parameterized patch of the background template model which corresponds to the camera's current field-of-view, wherein the template matching cost function takes a parameter x as input and outputs a normalized scalar score corresponding to a match between the camera's current field-of-view and the parameterized patch of the background template model using an image similarity measure selected from the group consisting of normalized cross correlation and L2 distances, wherein the template matching cost function is minimized through utilization of a plurality of particles which operates as a cooperative swarm in sampling the cost function over a search domain of the background template model and iteratively migrates towards the parameter x*; for each current field-of-view, continuously matching the camera's current field-of-view with the parameterized patch of the background template model; subtracting the parameterized patch of the background template model from the camera's current field-of-view to extract a foreground mask; and generating a display of the foreground mask for detecting at least one object of interest within the foreground mask.
 6. A method for background estimation as set forth in claim 5, wherein the cost function to be optimized is J(x)=d(I(x),Io), with J:

²→[0, 1], where I_(o)∈

^(w×h) represents the image corresponding to the current scene, I(x)∈

^(w×h) represents an image corresponding to the parameterized patch of the background template model centered at x∈Ω⊂R² having the same dimensions as I_(o)∈

^(w×h), where x is an input parameter, d(.) represents an image similarity measure, R denotes the set of real numbers, w is the width of the image, h is the height of the image, ∈ denotes an element of, Ω represents the search domain, and → represents a function arrow.
 7. A method for background estimation as set forth in claim 6, wherein the image similarity measure varies with respect to at least one misalignment between the background template and the current scene.
 8. A method for background estimation as set forth in claim 7, wherein in the act of optimizing the cost function, the plurality of particles begin at a randomly initialized state, where each particle migrates towards the optimal solution in the search domain according to the following: x _(i)(t+1)=F(x _(i)(t),pbest_(i)(t),gbest(t)), where x(t) corresponds to a particle i's trajectory, pbest represents a particle's current best solution found up to time t, gbest represents a current global best solution among all particles up to time t, and F(.) represents a particle's dynamic evolution as a function of its current position or state, pbest, and gbest.
 9. A computer program product for background estimation, the computer program product comprising computer-readable instruction means stored on a non-transitory computer-readable medium that are executable by a computer having a processor for causing the processor to perform operations of: constructing and learning a background template model of a field-of view of a scene captured with a camera a priori; capturing a current image of the scene with the camera, the current image of the scene having a dynamically changing field-of-view of the scene that is smaller than the field-of-view of the background template model; minimizing a template matching cost function to identify a parameter x* for a parameterized patch of the background template model which corresponds to the camera's current field-of-view, wherein the template matching cost function takes a parameter x as input and outputs a normalized scalar score corresponding to a match between the camera's current field-of-view and the parameterized patch of the background template model using an image similarity measure selected from the group consisting of normalized cross correlation and L2 distances, wherein the template matching cost function is minimized through utilization of a plurality of particles which operates as a cooperative swarm in sampling the cost function over a search domain of the background template model and iteratively migrates towards the parameter x*; for each current field-of-view, continuously matching the camera's current field-of-view with the parameterized patch of the background template model; subtracting the parameterized patch of the background template model from the camera's current field-of-view to extract a foreground mask; and generating a display of the foreground mask for detecting at least one object of interest within the foreground mask.
 10. A computer program product for background estimation as set forth in claim 9, wherein the cost function to be optimized is J(x)=d(I(x),Io), with J:

²→[0, 1], where I_(o)∈

^(w×h) represents the image corresponding to the current scene, I(x)∈

^(w×h) represents an image corresponding to the parameterized patch of the background template model centered at x∈Ω⊂R² having the same dimensions as I_(o)∈

^(w×h), where x is an input parameter, d(.) represents an image similarity measure, R denotes the set of real numbers, w is the width of the image, h is the height of the image, ∈ denotes an element of, Ω represents the search domain, and → represents a function arrow.
 11. A computer program product for background estimation as set forth in claim 10, wherein the image similarity measure varies with respect to at least one misalignment between the background template and the current scene.
 12. A computer program product for background estimation as set forth in claim 11, wherein in the act of optimizing the cost function, the plurality of particles begin at a randomly initialized state, where each particle migrates towards the optimal solution in the search domain according to the following: x _(i)(t+1)=F(x _(i)(t),pbest_(i)(t),gbest(t)), where x(t) corresponds to a particle i's trajectory, pbest represents a particle's current best solution found up to time t, gbest represents a current global best solution among all particles up to time t, and F(.) represents a particle's dynamic evolution as a function of its current position or state, pbest, and gbest. 